<template>
  <div class="app-container">
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <el-button
          type="primary"
          plain
          icon="el-icon-search"
          size="mini"
          @click="handleSearch"
          >查询
        </el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button
          type="warning"
          plain
          icon="el-icon-download"
          size="mini"
          :loading="exportLoading"
          @click="handleExport('#assistDevice', '辅助设备')"
          v-hasPermi="['device:assistDevice:export']"
          >导出
        </el-button>
      </el-col>

      <!-- 分页效果 -->
      <el-col :span="2.2" style="position: absolute; right: 0px; top: 0">
        <Page
          style="margin-right: 0px"
          :current="queryParams.pageNum"
          :page-size="queryParams.pageSize"
          :total="total"
          @on-change="pageChange"
          simple
        ></Page>
      </el-col>
      <right-toolbar
        :showSearch.sync="showSearch"
        @queryTable="getList"
      ></right-toolbar>
    </el-row>

    <el-table
      highlight-current-row
      border
      stripe
      v-loading="loading"
      id="assistDevice"
      height="400px"
      :data="assistDeviceList"
      @row-click="sbmClick"
      :header-cell-style="{ 'text-align': 'center' }"
    >
      <el-table-column
        label="#"
        type="index"
        fixed="left"
        width="40"
        align="center"
      />
      <el-table-column
        label="设备编号"
        :show-overflow-tooltip="true"
        width="135"
        align="center"
        prop="sbmCode"
      />
      <el-table-column
        label="设备类型"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmType"
      >
        <template v-slot="scope">
          <dict-tag :options="deviceTypeList" :value="scope.row.sbmType" />
        </template>
      </el-table-column>
      <el-table-column
        label="设备名称"
        :show-overflow-tooltip="true"
        width="135"
        prop="sbmName"
      />
      <el-table-column
        label="规格型号"
        :show-overflow-tooltip="true"
        width="135"
        prop="sbmGgxh"
      />
      <el-table-column
        label="供应厂商"
        :show-overflow-tooltip="true"
        width="150"
        prop="sbmGycs"
      />
      <el-table-column
        label="购买日期"
        :show-overflow-tooltip="true"
        align="center"
        prop="sbmCgrq"
        width="150"
      >
        <template v-slot="scope">
          <span>{{ parseTime(scope.row.sbmCgrq, "{y}-{m}-{d}") }}</span>
        </template>
      </el-table-column>
      <el-table-column
        label="联系方式"
        :show-overflow-tooltip="true"
        width="150"
        prop="sbmLxfs"
      />
      <el-table-column
        label="责任人员"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmZrry"
      />
      <el-table-column
        label="设备状态"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmSbzt"
      >
        <template v-slot="scope">
          <dict-tag :options="deviceCondition" :value="scope.row.sbmSbzt" />
        </template>
      </el-table-column>
      <el-table-column
        label="备注"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmDesc"
      />
      <el-table-column
        label="建立人员"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmJlry"
      />
      <el-table-column
        label="建立日期"
        :show-overflow-tooltip="true"
        align="center"
        prop="sbmJlrq"
        width="150"
      >
        <template v-slot="scope">
          <span>{{
            parseTime(scope.row.sbmJlrq, "{y}-{m}-{d}  {h}:{i}:{s}")
          }}</span>
        </template>
      </el-table-column>
      <el-table-column
        label="更改人员"
        :show-overflow-tooltip="true"
        width="100"
        align="center"
        prop="sbmGgry"
      />
      <el-table-column
        label="更改日期"
        :show-overflow-tooltip="true"
        align="center"
        prop="sbmGgrq"
        width="150"
      >
        <template v-slot="scope">
          <span>{{
            parseTime(scope.row.sbmGgrq, "{y}-{m}-{d}  {h}:{i}:{s}")
          }}</span>
        </template>
      </el-table-column>
    </el-table>

    <!-- 下表 -->
    <el-table
      highlight-current-row
      border
      stripe
      id="deviceCheckStatus"
      v-loading="loading"
      height="350px"
      :data="devicePreserve"
      :header-cell-style="{ 'text-align': 'center' }"
    >
      <el-table-column label="#" type="index" width="40" align="center" />
      <el-table-column
        label="记录类型"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
      >
        <span>保养</span>
      </el-table-column>
      <el-table-column
        label="开始时间"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylKssj"
      >
        <template v-slot="scope">
          <span>{{
            parseTime(scope.row.bylKssj, "{y}-{m}-{d} {h}:{i}:{s}")
          }}</span>
        </template>
      </el-table-column>
      <el-table-column
        label="结束时间"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylJssj"
      >
        <template v-slot="scope">
          <span>{{
            parseTime(scope.row.bylJssj, "{y}-{m}-{d} {h}:{i}:{s}")
          }}</span>
        </template>
      </el-table-column>
      <el-table-column
        label="用时"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
      />
      <el-table-column
        label="状态"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylZtbz"
      >
        <template v-slot="scope">
          <span v-if="scope.row.bylZtbz == 1">进行中</span>
          <span v-if="scope.row.bylZtbz == 2">已完成</span>
        </template>
      </el-table-column>
      <el-table-column
        label="保养类别"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylBylb"
      >
        <template v-slot="scope">
          <dict-tag :options="upKeepList" :value="scope.row.bylBylb" />
        </template>
      </el-table-column>
      <el-table-column
        label="责任人员"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylByry"
      />
      <el-table-column
        label="计划单号"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylBpdh"
      />
      <el-table-column
        label="完成人员"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylJary"
      />
      <el-table-column
        label="完成日期"
        :show-overflow-tooltip="true"
        width="150"
        align="center"
        prop="bylJarq"
      >
        <template v-slot="scope">
          <span>{{
            parseTime(scope.row.bylJarq, "{y}-{m}-{d} {h}:{i}:{s}")
          }}</span>
        </template>
      </el-table-column>
      <el-table-column label="操作" align="center" width="138">
        <template #default="scope">
          <el-button
            size="mini"
            type="text"
            @click="handleProcessFiles(scope.row)"
            v-hasPermi="['device:assistDevice:query']"
            :disabled="scope.row.docPath == null"
            >附件
          </el-button>
          <el-button
            size="mini"
            type="text"
            @click="recordClick(scope.row)"
            :disabled="scope.row.bylZtbz !== 2"
            >保全记录
          </el-button>
        </template>
      </el-table-column>
    </el-table>

    <!--   查询对话框   -->
    <el-dialog
      :title="title"
      v-model="openSearch"
      :close-on-click-modal="false"
      draggable
      width="400px"
      append-to-body
    >
      <el-form
        :model="queryParams"
        ref="queryForm"
        :inline="true"
        v-show="showSearch"
        label-width="88px"
      >
        <el-col :span="24">
          <el-form-item label="设备编号" prop="sbmCode">
            <el-input
              v-model="queryParams.sbmCode"
              placeholder="请输入设备编号"
              clearable
              size="small"
              @keyup.enter.native="handleQuery"
            />
          </el-form-item>
        </el-col>
        <el-col :span="24">
          <el-form-item label="设备名称" prop="sbmName">
            <el-input
              v-model="queryParams.sbmName"
              placeholder="请输入设备名称"
              clearable
              size="small"
              @keyup.enter.native="handleQuery"
            />
          </el-form-item>
        </el-col>
        <el-col :span="24">
          <el-form-item label="设备类型" prop="sbmType">
            <el-select
              v-model="queryParams.sbmTypes"
              multiple
              placeholder="请选择设备类型"
              clearable
              size="small"
            >
              <el-option
                v-for="item in deviceTypeList"
                :key="item.dictValue"
                :label="'[' + item.dictValue + ']' + item.dictLabel"
                :value="item.dictValue"
              />
            </el-select>
          </el-form-item>
        </el-col>
        <el-col :span="24">
          <el-form-item
            style="margin-top: 25px; display: flex; justify-content: flex-end"
          >
            <el-button @click="cancel">取消</el-button>
            <el-button type="primary" @click="handleQuery">确认</el-button>
          </el-form-item>
        </el-col>
      </el-form>
    </el-dialog>

    <!-- 添加或修改辅助设备对话框 -->
    <el-dialog
      :title="title"
      v-model="open"
      :close-on-click-modal="false"
      draggable
      width="750px"
      append-to-body
    >
      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
        <el-col :span="12">
          <el-form-item label="设备类型" prop="sbmType">
            <el-select
              v-model="form.sbmType"
              class="input240"
              placeholder="请选择设备类型"
            >
              <el-option
                v-for="item in deviceTypeEfficient"
                :key="item.dictValue"
                :label="'[' + item.dictValue + ']' + item.dictLabel"
                :value="item.dictValue"
              />
            </el-select>
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="设备名称" prop="sbmName">
            <el-input v-model="form.sbmName" placeholder="请输入设备名称" />
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="规格型号" prop="sbmGgxh">
            <el-input
              v-model="form.sbmGgxh"
              class="input240"
              placeholder="请输入规格型号"
            />
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="供应厂商" prop="sbmGycs">
            <el-input v-model="form.sbmGycs" placeholder="请输入供应厂商" />
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="购买日期" prop="sbmCgrq">
            <el-date-picker
              clearable
              v-model="form.sbmCgrq"
              type="date"
              style="width: 240px"
              value-format="yyyy-MM-dd"
              placeholder="选择购买日期"
            >
            </el-date-picker>
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="联系方式" prop="sbmLxfs">
            <el-input v-model="form.sbmLxfs" placeholder="请输入联系方式" />
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="设备状态" prop="sbmSbzt">
            <el-select
              v-model="form.sbmSbzt"
              class="input240"
              placeholder="请选择设备状态"
            >
              <el-option
                v-for="item in deviceEfficientCondition"
                :key="item.dictValue"
                :label="'[' + item.dictValue + ']' + item.dictLabel"
                :value="item.dictValue"
              />
            </el-select>
          </el-form-item>
        </el-col>
        <el-col :span="12">
          <el-form-item label="责任人员" prop="sbmZrry">
            <el-input v-model="form.sbmZrry" placeholder="请输入责任人员" />
          </el-form-item>
        </el-col>
        <el-col :span="24">
          <el-form-item label="备注" prop="sbmDesc">
            <el-input v-model="form.sbmDesc" placeholder="请输入备注" />
          </el-form-item>
        </el-col>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button @click="cancel">取 消</el-button>
        <el-button type="primary" @click="submitForm">确 定</el-button>
      </div>
    </el-dialog>

    <!-- 修改设备保养作业对话框 -->
    <el-dialog
      :class="$style.tabSbby"
      :title="title"
      v-model="openFix"
      :close-on-click-modal="false"
      draggable
      width="830px"
      append-to-body
    >
      <el-form
        :model="formFix"
        :rules="rules"
        ref="formSbby"
        style="display: flex; flex-wrap: wrap"
        label-width="80px"
      >
        <el-form-item label="保养单号" prop="bymDjbh">
          <el-input
            disabled
            v-model="formFix.bymDjbh"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>
        <el-form-item label="保养类别" prop="bymBylb">
          <el-select
            v-model="formFix.bymBylb"
            disabled
            size="mini"
            style="width: 180px"
            filterable
            placeholder="请选择保养类型"
          >
            <el-option
              v-for="dict in upKeepList"
              :key="dict.dictValue"
              :label="'[' + dict.dictValue + ']' + dict.dictLabel"
              :value="dict.dictValue"
            ></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="计划单号" prop="bymBpdh">
          <el-input
            disabled
            v-model="formFix.bymBpdh"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="产品型号" prop="bymCpxh">
          <el-input
            disabled
            v-model="formFix.bymCpxh"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="工装编号" prop="bymGzbh">
          <el-input
            disabled
            v-model="formFix.bymGzbh"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="使用设备" prop="bymSysb">
          <el-input
            disabled
            v-model="formFix.bymSysb"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="模具编号" prop="bymMjbh">
          <el-input
            disabled
            v-model="formFix.bymMjbh"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="模具名称" prop="mjmMjmc">
          <el-input
            disabled
            v-model="formFix.mjmMjmc"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="模具尺寸" prop="mjmMjgg">
          <el-input
            disabled
            v-model="formFix.mjmMjgg"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="制作时间" prop="mjmDcrq">
          <el-input
            disabled
            v-model="formFix.mjmDcrq"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>

        <el-form-item label="腔型数量" prop="mjmXsms">
          <el-input
            disabled
            v-model="formFix.mjmXsms"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>
        <el-form-item label="样件描述" prop="bymYjms">
          <el-input
            disabled
            v-model="formFix.bymYjms"
            style="width: 180px"
            size="mini"
          />
        </el-form-item>
      </el-form>
      <el-tabs v-model="activeName">
        <el-tab-pane label="保全工作" name="first">
          <hd-table
            :columns="[
              { title: '#', type: 'index', width: '40' },
              { title: '保全类', key: 'bnlNrlb', width: '100' },
              { title: '保全项目', key: 'bnlNrms', width: '348' },
              { title: '保养内容', key: 'bydBynr', width: '100' },
              { title: '保全人员', key: 'bydZrry', width: '100' },
              { title: '备件情况', key: 'bydDesc', width: '100' },
            ]"
            v-model="maintenanceWorkList"
            :readOnly="true"
          >
            <template #bydBynr="scope">
              <el-input disabled v-model="scope.row.bydBynr" />
            </template>
            <template #bydZrry="scope">
              <el-input disabled v-model="scope.row.bydZrry" />
            </template>
            <template #bydDesc="scope">
              <el-input disabled v-model="scope.row.bydDesc" />
            </template>
          </hd-table>
        </el-tab-pane>
        <el-tab-pane label="恢复精度工作" name="second">
          <hd-table
            :columns="sys_m_child_3"
            v-model="recoveryAccuracyList"
            :readOnly="true"
          />
        </el-tab-pane>
        <el-tab-pane label="其他保全检查项目" name="third">
          <hd-table
            :columns="[
              { title: '#', type: 'index', width: '40' },
              { title: '检查项目', key: 'bydJcxmms' },
              {
                title: '是否检查',
                key: 'bydChkjg',
                width: '120',
                align: 'center',
              },
            ]"
            v-model="otherProjectsList"
            :readOnly="true"
          >
            <template #bydChkjg="scope"
              ><el-checkbox disabled v-model="scope.row.bydChkjg"
            /></template>
          </hd-table>
        </el-tab-pane>
      </el-tabs>
      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="openFix = false">关 闭</el-button>
      </div>
    </el-dialog>
  </div>
</template>

<script>
import {
  listAssistDevice,
  delAssistDevice,
  addAssistDevice,
  updateAssistDevice,
  getAssistDeviceById,
} from "@/api/device/assistDevice";
import { getEffectiveDeviceType } from "@/api/device/deviceType";
import { exportTable } from "@/utils/ruoyi";
import {
  listMoldDetail,
  listPreserveContext,
  listPreserveInfo,
} from "@/api/device/preserveWork";
import HdTable from "@/components/HdTable";

export default {
  name: "AssistDeviceSelect",
  components: { HdTable },
  data() {
    return {
      // 遮罩层
      loading: true,
      // 导出遮罩层
      exportLoading: false,
      tableH: document.body.clientHeight - 290,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      openSearch: false,
      // 默认选择第一个表
      activeName: "first",
      // 总条数
      total: 0,
      // 辅助设备表格数据
      assistDeviceList: [],
      // 设备类型
      deviceTypeList: [],
      // 有效的设备类型
      deviceTypeEfficient: [],
      // 设备状态字典
      deviceCondition: [],
      // 保全工作
      maintenanceWorkList: [],
      // 恢复精度工作
      recoveryAccuracyList: [],
      // 其他保全项目检查
      otherProjectsList: [],
      // 保养类别
      upKeepList: [],
      // 保养表
      devicePreserve: [],
      // 有效的设备状态字典
      deviceEfficientCondition: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      openFix: false,
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 20,
        sbmCode: null,
        sbmType: null,
        sbmName: null,
        sbmTypes: null,
      },
      // 表单参数
      form: {},
      formFix: {},
      // 表单校验
      rules: {
        sbmType: [
          { required: true, message: "设备类型不能为空", trigger: "blur" },
        ],
        sbmSbzt: [
          { required: true, message: "设备状态不能为空", trigger: "blur" },
        ],
        sbmName: [
          { required: true, message: "设备名称不能为空", trigger: "blur" },
        ],
      },
      sys_m_child_3: [
        {
          title: "#",
          type: "index",
          width: 40,
          align: "center",
          fixed: "left",
        },
        {
          type: "selection",
          width: 40,
        },
        {
          title: "设备问题",
          key: "bydWtms",
          minWidth: 120,
          sortable: true,
        },
        {
          title: "分析产生原因",
          key: "bydYyms",
          minWidth: 150,
          sortable: true,
        },
        {
          title: "解决措施",
          key: "bydGsms",
          sortable: true,
        },
        {
          title: "维修人员",
          key: "bydZrry",
          minWidth: 120,
          sortable: true,
        },
        {
          title: "备件情况",
          key: "bydDesc",
          width: 120,
          sortable: true,
        },
      ],
    };
  },
  created() {
    getEffectiveDeviceType("0").then((res) => {
      this.deviceTypeEfficient = res.data;
      for (let item of this.deviceTypeEfficient) {
        item.dictLabel = item.dtypeName;
        item.listClass = "default";
        item.dictValue = item.dtypeCode;
      }
    });
    getEffectiveDeviceType().then((res) => {
      this.deviceTypeList = res.data;
      for (let item of this.deviceTypeList) {
        item.dictLabel = item.dtypeName;
        item.listClass = "default";
        item.dictValue = item.dtypeCode;
      }
    });
    this.getDicts("mould_status").then((response) => {
      this.deviceEfficientCondition = response.data;
    });
    this.getAllDicts("mould_status").then((response) => {
      this.deviceCondition = response.data;
    });
    this.getAllDicts("device_upkeep_style").then((response) => {
      this.upKeepList = response.data;
    });
    this.getList();
  },
  methods: {
    /** 查询辅助设备列表 */
    getList() {
      this.loading = true;
      listAssistDevice(this.queryParams).then((response) => {
        this.assistDeviceList = response.rows;
        this.total = response.total;
        this.loading = false;
      });
    },

    // 取消按钮
    cancel() {
      this.open = false;
      this.openSearch = false;
      this.reset();
    },
    // 表单重置
    reset() {
      this.form = {
        sbmId: null,
        sbmCode: null,
        sbmType: null,
        sbmTypes: null,
        sbmName: null,
        sbmGgxh: null,
        sbmGycs: null,
        sbmCgrq: null,
        sbmLxfs: null,
        sbmZrry: null,
        sbmDesc: null,
        sbmSbzt: null,
        sbmJlry: null,
        sbmJlrq: null,
        sbmGgry: null,
        sbmGgrq: null,
      };
      this.resetForm("form");
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.assistDeviceList = [];
      this.getList();
      this.openSearch = false;
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    /** 多选框选中数据 */
    handleSelectionChange(selection) {
      this.ids = selection.map((item) => item.sbmId);
      this.single = selection.length !== 1;
      this.multiple = !selection.length;
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "添加辅助设备";
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.reset();
      const sbmId = row.sbmId || this.ids;
      getAssistDeviceById(sbmId).then((response) => {
        this.form = response.data;
        this.open = true;
        this.title = "修改辅助设备";
      });
    },

    handleSearch() {
      this.reset();
      this.title = "查询辅助设备";
      this.openSearch = true;
    },
    /** 提交按钮 */
    submitForm() {
      this.$refs["form"].validate((valid) => {
        if (valid) {
          if (this.form.sbmId != null) {
            updateAssistDevice(this.form).then((response) => {
              this.msgSuccess("修改成功");
              this.open = false;
              this.getList();
            });
          } else {
            addAssistDevice(this.form).then((response) => {
              this.msgSuccess("新增成功");
              this.open = false;
              this.getList();
            });
          }
        }
      });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const sbmIds = row.sbmId || this.ids;
      this.$confirm(
        '是否确认删除辅助设备编号为"' + sbmIds + '"的数据项?',
        "警告",
        {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning",
        }
      )
        .then(function () {
          return delAssistDevice(sbmIds);
        })
        .then(() => {
          this.getList();
          this.msgSuccess("删除成功");
        })
        .catch(() => {});
    },
    /** 导出按钮操作 */
    handleExport(a, b) {
      exportTable(a, b);
    },
    pageChange(page) {
      this.queryParams.pageNum = page;
      this.getList();
    },
    /** 表格点击事件 */
    sbmClick(row) {
      // 获取设备保养相关信息
      listMoldDetail(row.sbmCode).then((res) => {
        this.devicePreserve = res.data;
      });
    },
    /** 附件点击事件 */
    handleProcessFiles(row) {
      let files = process.env.VUE_APP_BASE_API + row.docPath;
      window.open(files);
    },
    /** 保养记录点击事件 */
    recordClick(row) {
      const id = row.bylDjbh;
      listPreserveInfo(id).then((res) => {
        this.formFix = res.data;
      });
      listPreserveContext(id, "1").then((res) => {
        this.maintenanceWorkList = res.data;
      });
      listPreserveContext(id, "2").then((res) => {
        this.recoveryAccuracyList = res.data;
      });
      listPreserveContext(id, "3").then((res) => {
        this.otherProjectsList = res.data;
      });
      this.openFix = true;
    },
  },
};
</script>

<style module lang="scss">
.hdDivButton {
  button {
    width: calc(50% - 5px);
  }
}

.tabSbby {
  :global {
    .el-form-item {
      margin-bottom: 5px;
    }
    .el-table .cell {
      height: 28px;
      line-height: 28px;
    }
    .el-input--medium .el-input__inner {
      height: 28px;
      line-height: 28px;
      padding: 0px;
    }
  }
}
</style>
